package com.yedean.factory.aop;

import com.yedean.factory.BeansException;
import com.yedean.factory.config.BeanPostProcessor;
import com.yedean.factory.property.PropertyValues;

public interface InstantiationAwareBeanPostProcessor extends BeanPostProcessor {

    /**
     * 实例化之前的bean前置处理 用于代理对象提前创建
     */
    Object postProcessBeforeInstantiation(Class<?> beanClass, String beanName) throws BeansException;


    /**
     * 实例化完成后 处理bean属性值
     */
    PropertyValues postProcessPropertyValues(PropertyValues pvs, Object bean, String beanName)throws BeansException;
    
    
    
    default Object getEarlyBeanReference(Object bean,String beanName){
        return bean;
    }
}
